<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!doctype html>
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>学科管理</title>
    
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	
	<jsp:include page="/WEB-INF/views/common.jsp"></jsp:include>
	<script type="text/javascript" src="<%=path%>/resources/script/subjectManage/subject_list.js"></script>
	<script type="text/javascript" src="<%=path%>/resources/script/jquery.qrcode.min.js"></script>
	<script type="text/javascript" src="<%=path%>/resources/script/jquery.jqprint-0.3.js"></script>
  	<style type="text/css">
        @media screen {
            #canvas {display: block;}
            #image {display: none;}
        }
        @media print{
            #canvas {display: none;}
   			#image{
   				margin: 300px;
   				display: block;
   			}
        }
	</style>
  </head>
  
  <body class="easyui-layout" fit="true">
    <div data-options="region:'west',split:true" title="专业树" style="width:250px;">
		<ul id="subject_tree" class="easyui-tree"></ul>
	</div>
	<div data-options="region:'center'">
	    <div class="easyui-layout" data-options="fit:true">
	    	<div data-options="region:'center'">
	    		 <!-- DataGrid -->
			    <table id="dg" class="easyui-datagrid" title="学科列表" style="width: auto; height: auto;"
			    	data-options="url:'subject/queryList',
			    			fit:true,
			    			singleSelect:true,
			    			rownumbers:true,
			    			toolbar:'#tb',
			    			onClickRow:dgClickRow,
			    			onLoadSuccess:dgLoad,
			    			pagination:true">
			    	<thead>
			    		<tr>
			    			<th data-options="field:'id',hidden:true">学科ID</th>
			    			<th data-options="field:'name', width:150">学科名称</th>
			    			<th data-options="field:'remark', width:200">描述</th>
			    			<th data-options="field:'createTime', width:150">创建时间</th>
			    		</tr>
			    	</thead>
			    </table>
			    
			    <!-- toolbar -->
			    <div id="tb" style="padding: 5px; height: auto;">
			    	<!-- search -->
			    	<div>
			    		<table>
			    			<tr>
			    				<td>学科名称：<input class="easyui-validatebox edit-input" id="name" name="name" style="width: 150px;" /></td>
			    				<td><a href="javascript:void(0);" class="easyui-linkbutton" iconCls="icon-search" onclick="doSearch();">查询</a></td>
			    				<td><a href="javascript:void(0);" class="easyui-linkbutton" iconCls="icon-reload" onclick="reSearch();">重置</a></td>
			    			</tr>
			    		</table>
			    	</div>
			    	<!-- opreate -->
			    	<div style="margin-bottom: 5px; text-align: right;">
			    		<%@include file="/WEB-INF/views/common/operate.jsp" %>
			    		<!-- <a href="javascript:void(0);" id="add" class="easyui-linkbutton" title="添加" iconCls="icon-add" plain="true">添加</a>
			    		<a href="javascript:void(0);" id="edit" class="easyui-linkbutton" title="修改" iconCls="icon-edit" plain="true">修改</a>
			    		<a href="javascript:void(0);" id="remove" class="easyui-linkbutton" title="删除" iconCls="icon-remove" plain="true">删除</a>
			    		<a href="javascript:void(0);" id="grantRole" class="easyui-linkbutton" title="添加" iconCls="icon-edit" plain="true">赋予角色</a> -->
			    	</div>
			    </div>
	    	</div>
	    	<div data-options="region:'east'" style="width:330px; padding-top:150px; padding-left: 50px;">
				<a href="javascript:void(0);" id="printBtn" class="easyui-linkbutton" title="打印" iconCls="icon-print" plain="true">打印</a>
				<div id="qcode" style="margin: 0 atuo;"></div>
				<img id="image" src="" />
			</div>
	    </div>
    </div>
    <!-- add/edit window -->
    <div id="win" class="easyui-window"
    	 data-options="modal:true,
    	 				closed:true,
    	 				maximizable:true,
    	 				minimizable:false,
    	 				collapsible:false,
    	 				iconCls:'icon-save',
    	 				draggable:false">
    	 <iframe id="contentFrame" src="" width=100% height=99% marginwidth=0 framespacing=0 marginheight=0 frameborder=no scrolling=no></iframe>
    </div>
  </body>
</html>
